import request from '@/utils/request'

// 查询存储数据预警信息列表
export function listAlarms(query) {
  return request({
    url: '/storage/alarms/list',
    method: 'get',
    params: query
  })
}

// 查询存储数据预警信息详细
export function getAlarms(alarmId) {
  return request({
    url: '/storage/alarms/' + alarmId,
    method: 'get'
  })
}

// 新增存储数据预警信息
export function addAlarms(data) {
  return request({
    url: '/storage/alarms',
    method: 'post',
    data: data
  })
}

// 修改存储数据预警信息
export function updateAlarms(data) {
  return request({
    url: '/storage/alarms',
    method: 'put',
    data: data
  })
}

// 删除存储数据预警信息
export function delAlarms(alarmId) {
  return request({
    url: '/storage/alarms/' + alarmId,
    method: 'delete'
  })
}
